<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <link href="/assets/css/text.css" rel="stylesheet" type="text/css">
    <link href="/assets/css/main.css" rel="stylesheet" type="text/css">
    <link href="/assets/css/content.css" rel="stylesheet" type="text/css">
    <script language="javascript" src="/assets/js/common.js"></script>
    <script language="javascript" src="/assets/js/general.js"></script>
    <script language="JavaScript" type="text/JavaScript">
    </script>
    <style>
        #title {
            width: 92%;
            border: 0px;
            margin-bottom: 10px;
        }

        #title td {
            text-align: center;
            height: 20px;
            line-height: 150%
        }

        #title div {
            background-image: url(/assets/img/dot_02.gif);
            background-position: left top;
            background-repeat: no-repeat;
            margin: 0 auto;
            padding-left: 20px;
            text-align: left;
            width: 10%;
            font-size: 15px;
            font-weight: bold;
            color: #CC0000;
            letter-spacing: 2px;
        }
    </style>
    <script>
        <c:if test="${not empty msg}">
        alert('${msg}');
        </c:if>
    </script>
</head>
<body>

<table cellspacing="0" cellpadding="0" id="title" align="center">
    <tbody>
    <tr>
        <td nowrap="nowrap">
            <div>用户管理</div>
        </td>
    </tr>
    </tbody>
</table>
<table cellspacing="0" cellpadding="0" class="subtitle">
    <tbody>
    <tr>
        <td class="subtitle">用户管理说明</td>
        <td>&nbsp;</td>
        <td id="rightbg">&nbsp;</td>
    </tr>
    </tbody>
</table>

<table cellpadding="0" cellspacing="0" class="explain_tab">
    <tbody>
    <tr>
        <td class="explain">
            <p align="left">用户管理这个模块中所管理的用户是系统内的全部用户，所有用户都一视同仁，并不区分他们是总经理、 副总经理还是财务，有权限的管理员在此可以设定用户的基本信息，赋予或收回用户角色权限，设定用户的管理范围。一般来说，在此处增加的用户均视同为“管理员”，在此处增加的“工人”， 仅仅说明这个管理员具有“工人”的角色权限，而他本身并不是真正意义上的工人。增加工人，增加财务的操作应当在对应模块中完成。</p>
        </td>
    </tr>
    </tbody>
</table>
<br>
<table cellpadding="0" cellspacing="0" class="datalist" align="center">
    <tbody>
    <tr>
        <td colspan="4">
            <a href="/export.do">导出Excel</a>&nbsp;
            <c:if test="${not empty msg}">
               <a href="file:///C:/userlogin.xls">打开文件</a>
               <%--<a href="file://localhost/Users/mioko/Desktop/userlogin.xls">打开文件</a>--%>
            </c:if>
        </td>
    </tr>
    <tr align="center">
        <th name="td0">用户账号</th>
        <th name="td1">用户名</th>
        <th name="td2">用户密码</th>
        <th name="td3">用户角色</th>
        <th name="td4">删除</th>
    </tr>
    <c:forEach items="${user2}" var="u">
        <tr align="center">
            <td name="td0">${u.userID}</td>
            <td name="td1">${u.username}</td>
            <td name="td2">${u.password}</td>
            <td name="td2">${u.position}</td>
            <td name="td3"><a href="/deluser.do?userID=${u.userID}"><img src="/assets/img/icodelete.gif"/></a></td>
        </tr>
    </c:forEach>
    </tbody>
</table>
</body>
</html>